package com.smarthealthcare.device.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.smarthealthcare.device.mapper.ManufacturerMapper;
import com.smarthealthcare.device.domain.Manufacturer;
import com.smarthealthcare.device.service.IManufacturerService;

/**
 * 设备厂家Service业务层处理
 * 
 * @author fry
 * @date 2024-11-22
 */
@Service
public class ManufacturerServiceImpl implements IManufacturerService 
{
    @Autowired
    private ManufacturerMapper manufacturerMapper;

    /**
     * 查询设备厂家
     * 
     * @param id 设备厂家主键
     * @return 设备厂家
     */
    @Override
    public Manufacturer selectManufacturerById(Long id)
    {
        return manufacturerMapper.selectManufacturerById(id);
    }

    /**
     * 查询设备厂家列表
     * 
     * @param manufacturer 设备厂家
     * @return 设备厂家
     */
    @Override
    public List<Manufacturer> selectManufacturerList(Manufacturer manufacturer)
    {
        return manufacturerMapper.selectManufacturerList(manufacturer);
    }

    /**
     * 新增设备厂家
     * 
     * @param manufacturer 设备厂家
     * @return 结果
     */
    @Override
    public int insertManufacturer(Manufacturer manufacturer)
    {
        return manufacturerMapper.insertManufacturer(manufacturer);
    }

    /**
     * 修改设备厂家
     * 
     * @param manufacturer 设备厂家
     * @return 结果
     */
    @Override
    public int updateManufacturer(Manufacturer manufacturer)
    {
        return manufacturerMapper.updateManufacturer(manufacturer);
    }

    /**
     * 批量删除设备厂家
     * 
     * @param ids 需要删除的设备厂家主键
     * @return 结果
     */
    @Override
    public int deleteManufacturerByIds(Long[] ids)
    {
        return manufacturerMapper.deleteManufacturerByIds(ids);
    }

    /**
     * 删除设备厂家信息
     * 
     * @param id 设备厂家主键
     * @return 结果
     */
    @Override
    public int deleteManufacturerById(Long id)
    {
        return manufacturerMapper.deleteManufacturerById(id);
    }
}
